Skip to content

Conversation

@github-actions
Copy link
Contributor

@github-actions github-actions bot commented Oct 8, 2025

This PR was opened by the Changesets release GitHub action. When you're ready to do a release, you can merge this and the packages will be published to npm automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to main, this PR will be updated.

Releases

[email protected]

Minor Changes

  • #5387 53dd7f1 Thanks @farskid! - Adds system.getAll that returns a record of running actors within the system by their system id

    const childMachine = createMachine({});
    const machine = createMachine({
      // ...
      invoke: [
        {
          src: childMachine,
          systemId: 'test'
        }
      ]
    });
    const system = createActor(machine);
    
    system.getAll(); // { test: ActorRefFrom<typeof childMachine> }

@xstate/[email protected]

Minor Changes

  • #5323 cb08332 Thanks @davidkpiano! - Added support for effect-only transitions that don't trigger state updates. Now, when a transition returns the same state but includes effects, subscribers won't be notified of a state change, but the effects will still be executed. This helps prevent unnecessary re-renders while maintaining side effect functionality.

    it('should not trigger update if the snapshot is the same even if there are effects', () => {
      const store = createStore({
        context: { count: 0 },
        on: {
          doNothing: (ctx, _, enq) => {
            enq.effect(() => {
              // …
            });
            return ctx; // Context is the same, so no update is triggered
            // This is the same as not returning anything (void)
          }
        }
      });
    
      const spy = vi.fn();
      store.subscribe(spy);
    
      store.trigger.doNothing();
      store.trigger.doNothing();
    
      expect(spy).toHaveBeenCalledTimes(0);
    });

@github-actions github-actions bot force-pushed the changeset-release/main branch from 4f6c175 to ddbeb10 Compare October 9, 2025 12:43
@davidkpiano davidkpiano merged commit cf9bbee into main Oct 11, 2025
@davidkpiano davidkpiano deleted the changeset-release/main branch October 11, 2025 04:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants